import {request} from '@/utils/request'

// 查询工单信息（受理单）列表
export function todoList(query) {
  return request({
    url: '/workorder/woWorkOrder/todoList',
    method: 'get',
    params: query
  })
}

// 查询工单信息（延期申请单）列表
export function todoExtensionList(query) {
  return request({
    url: '/workorder/woExtension/todoList',
    method: 'get',
    params: query
  })
}

// 查询工单信息（督办申请单）列表
export function todoSuperviseList(query) {
  return request({
    url: '/workorder/woSupervise/todoList',
    method: 'get',
    params: query
  })
}
// 查询工单信息（不计考核申请单）列表
export function todoDisregardList(query) {
  return request({
    url: '/workorder/disregardKpi/todoList',
    method: 'get',
    params: query
  })
}


// 获得指定流程实例的任务列表list-by-process-instance-id
export function getTaskListByProcessInstanceId(query) {
  return request({
    url: '/workorder/woWorkOrder/list-by-process-instance-id',
    method: 'get',
    params: query
  })
}
// 验证任务分配
export function checkUserIdDoTask(taskId) {
  return request({
    url: '/common/baseflow/checkUserIdDoTask/' + taskId,
    method: 'get',
  })
}
// 获取图片
export function generateHighlightDiagram(processInstanceId) {
  return request({
    url: '/common/baseflow/generateHighlightDiagram/' + processInstanceId,
    method: 'get',
  })
}
// 流程配置按钮
export function getOptButton(taskDefinitionkey) {
  return request({
    url: '/common/baseflow/getOptButton/' + taskDefinitionkey,
    method: 'get',
  })
}

